using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._WorkflowManagerTools._Configuration
{
    /// <summary>
    /// <para>Import Job Data</para>
    /// <para>Imports configuration and job information from a Workflow Manager (Classic) repository to a destination repository.  This tool is most useful for setting up a repository similar to an existing repository, disconnected repository replica creation, and changing synchronization.</para>
    /// <para>将配置和作业信息从 Workflow Manager （Classic） 资料档案库导入到目标资料档案库。 此工具对于设置类似于现有存储库的存储库、创建断开连接的存储库副本以及更改同步最有用。</para>
    /// </summary>    
    [DisplayName("Import Job Data")]
    public class ImportJobData : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public ImportJobData()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_Input_File">
        /// <para>Input JXL/Acknowledgement</para>
        /// <para>The JXL file that contains the jobs and configuration elements generated using the Export Job Data tool.</para>
        /// <para>包含使用导出作业数据工具生成的作业和配置元素的 JXL 文件。</para>
        /// </param>
        /// <param name="_Input_Merge">
        /// <para>Merge</para>
        /// <para><xdoc>
        ///   <para>Specifies whether contents of the destination Workflow Manager (Classic) repository should be combined rather than overwritten with the contents of the input configuration file.
        ///   <bulletList>
        ///     <bullet_item>Checked—Combines the contents of the destination Workflow Manager (Classic) database with the contents of the input configuration file.  </bullet_item><para/>
        ///     <bullet_item>Unchecked—Replaces the entire contents of the destination Workflow Manager (Classic) database with the contents of the input configuration file.  </bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>指定是否应将目标 Workflow Manager （Classic） 资料档案库的内容与输入配置文件的内容合并而不是覆盖。
        ///   <bulletList>
        ///     <bullet_item>选中 - 将目标 Workflow Manager （Classic） 数据库的内容与输入配置文件的内容合并。</bullet_item><para/>
        ///     <bullet_item>未选中 - 将目标 Workflow Manager （Classic） 数据库的全部内容替换为输入配置文件的内容。</bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// </param>
        public ImportJobData(object _Input_File, _Input_Merge_value? _Input_Merge)
        {
            this._Input_File = _Input_File;
            this._Input_Merge = _Input_Merge;
        }
        public override string ToolboxName => "Workflow Manager Tools";

        public override string ToolName => "Import Job Data";

        public override string CallName => "wmx.ImportJobData";

        public override List<string> AcceptEnvironments => [];

        public override object[] ParameterInfo => [_Input_File, _Input_Merge.GetGPValue(), _Input_DatabasePath, _Input_Repository_Name, _Output_Status];

        /// <summary>
        /// <para>Input JXL/Acknowledgement</para>
        /// <para>The JXL file that contains the jobs and configuration elements generated using the Export Job Data tool.</para>
        /// <para>包含使用导出作业数据工具生成的作业和配置元素的 JXL 文件。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input JXL/Acknowledgement")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _Input_File { get; set; }


        /// <summary>
        /// <para>Merge</para>
        /// <para><xdoc>
        ///   <para>Specifies whether contents of the destination Workflow Manager (Classic) repository should be combined rather than overwritten with the contents of the input configuration file.
        ///   <bulletList>
        ///     <bullet_item>Checked—Combines the contents of the destination Workflow Manager (Classic) database with the contents of the input configuration file.  </bullet_item><para/>
        ///     <bullet_item>Unchecked—Replaces the entire contents of the destination Workflow Manager (Classic) database with the contents of the input configuration file.  </bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para><xdoc>
        /// <para>指定是否应将目标 Workflow Manager （Classic） 资料档案库的内容与输入配置文件的内容合并而不是覆盖。
        ///   <bulletList>
        ///     <bullet_item>选中 - 将目标 Workflow Manager （Classic） 数据库的内容与输入配置文件的内容合并。</bullet_item><para/>
        ///     <bullet_item>未选中 - 将目标 Workflow Manager （Classic） 数据库的全部内容替换为输入配置文件的内容。</bullet_item><para/>
        ///   </bulletList>
        ///   </para>
        /// </xdoc></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Merge")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public _Input_Merge_value? _Input_Merge { get; set; }

        public enum _Input_Merge_value
        {
            /// <summary>
            /// <para>COMBINE</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("COMBINE")]
            [GPEnumValue("true")]
            _true,

            /// <summary>
            /// <para>REPLACE</para>
            /// <para></para>
            /// <para></para>
            /// </summary>
            [Description("REPLACE")]
            [GPEnumValue("false")]
            _false,

        }

        /// <summary>
        /// <para>Input Database Path</para>
        /// <para>The Workflow Manager (Classic) connection file that contains the connection information to the destination repository. If no connection file is specified, the current default Workflow Manager (Classic) database in the project will be used.</para>
        /// <para>包含与目标资料档案库的连接信息的 Workflow Manager （Classic） 连接文件。如果未指定连接文件，则将使用工程中的当前默认 Workflow Manager （Classic） 数据库。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Database Path")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _Input_DatabasePath { get; set; } = null;


        /// <summary>
        /// <para>Repository Name</para>
        /// <para>The name of the repository as specified in the Workflow Manager (Classic) system settings. This name should be unique within all the repositories in your cluster. If the repository name is not specified, the current default Workflow Manager (Classic) repository name will be used.</para>
        /// <para>在 Workflow Manager （Classic） 系统设置中指定的资料档案库的名称。此名称在集群中的所有存储库中应是唯一的。如果未指定资料档案库名称，则将使用当前默认的 Workflow Manager （Classic） 资料档案库名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Repository Name")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _Input_Repository_Name { get; set; } = null;


        /// <summary>
        /// <para>Status</para>
        /// <para></para>
        /// <para></para>
        /// <para></para>
        /// </summary>
        [DisplayName("Status")]
        [Description("")]
        [Option(OptionTypeEnum.derived)]
        public long? _Output_Status { get; set; }


        public ImportJobData SetEnv()
        {
            base.SetEnv();
            return this;
        }

    }

}